package org.hylexus.hadoop.hadoop_2_test.rpc;

import java.io.IOException;
import java.net.InetSocketAddress;

import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.ipc.RPC;

public class RPCClient {

	public static void main(String[] args) {
		try {
			RPCInterface proxy = RPC.getProxy(RPCInterface.class, RPCInterface.versionID,
					new InetSocketAddress("192.168.0.109", 8888), new Configuration());
			String string = proxy.hello("apache");
			System.err.println(string);
			RPC.stopProxy(proxy);
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
}
